<?php 
require_once 'mysql.php';	

class DbDriver {
	const TYPE_MYSQL = "mysql";
	
	static function factory($type, $host, $user, $pass, $name){
		switch ($type) {
			case self::TYPE_MYSQL:
				return new Mysql($host, $user, $pass, $name);
			
			default:
				return null;
		}
		
		// return new $type($host, $user, $pass, $name);
	}
	
}


